<%include file="include/head.html"%>
<div class="wrapper">
  <div id="div-home" class="main-info-box">
    <%include file="include/crumbs.html"%>
    <%include file="include/edit_nav.html"%>   
    <div class="div-info-body">
      <%if $history|@count gt 0%>
      <table>
	<th clsss="version">版本
	</th>
	<th clsss="date">日期
	</th>
	<th clsss="event">事件
	</th>
	<th clsss="author">贡献者
	</th>
	<th clsss="date">编辑时间
	</th>
	<th 1clsss="op">
	  操作
	</th>
	<% foreach name=history from=$history item=info %>
	<tr>
	  <td><%$info.id%>
	  </td>
	  <td><%$info.content.date%>
	  </td>
	  <td clsss="event"><%$info.content.event%>
	  </td>
	  <td>
	    <a href="/users/contribution?userid=<%$info.author_id%>"><%$info.author_name%></a>
	  </td>
	  <td><%$info.ts_created%>
	  </td>
	  <!-- <td> -->
	  <!--   <a href="/users/contribution?userid=<%$info.author_id%>"><%$info.author_name%></a> -->
	  <!-- </td> -->
	  <td class="op">
            <!-- <button history_id="<%$info.id%>" user_id="<%$user.id%>">恢复此版本 -->
            <!-- </button> -->
            <a href="/users/event_restore?eventid=<%$info.content.id%>&historyid=<%$info.id%>">恢复到此版本</a>
	  </td>
	</tr>
	<%/foreach%>
	<tr>
	  <td colspan="8">
	    <%$page%>
	  </td>
	</tr>
      </table>
      <%else%>
      <span class="warnning">
	没有历史记录！
      </span>
      <%/if%>
    </div>
    <div class="clear"></div>
  </div>
</div>
<%include file="include/bottom.html"%>
